#ifndef ZIGBEECONTROLPROTOCOL_H
#define ZIGBEECONTROLPROTOCOL_H

#include <QObject>
#include "Protocol/BaseProtocol.h"
#include "DataType/DataType.h"

class ZigbeeControlProtocol  : public BaseProtocol
{
    Q_OBJECT
public:
    explicit ZigbeeControlProtocol(QObject *parent = 0);
    QList<Package> parseData(QByteArray data);
    QByteArray generateData(Package package);

    enum FunctionCode
    {
        SendControlPointList = 0x05,
        AiringControlPinotList=0x0D,
        EquipmentIntoNet = 0x80,
        ReceiveControlPointList = 0x83,
        DeliverCmd=0x89,
        ActionCmd=0x51

    };


private:
    enum CheckSteps
    {
        CHECK_HEAD,
        CHECK_LENGTH,
        ChECK_RESERVED,
        CHECK_FUNCTION,
        CHECK_BODY,
        CHECK_CHECKCODE,
    };

};

#endif // ZIGBEECONTROLPROTOCOL_H
